package vanjalee.bs.com;

import java.util.List;

import vanjalee.bs.com.control.DataController;
import vanjalee.bs.com.control.ImportExportController;
import vanjalee.bs.com.control.model.Part;
import vanjalee.bs.com.control.model.Weapon;

public class Main {

	

	public static void main(String[] args) {
		
		 testHTMLImport();
		 // testFileImport();

	}

	public static void printList(List<?> items) {
		int i = 1;
		for (Object o : items) {
			System.out.println(i + ". " + o.toString());
			++i;
		}
	}

	public static void testFileImport() {
		DataController dataController = new DataController();
		
		System.out.println("\nTest Close Combat Weapons\n");
		List<Weapon> weaponsCloseCombat = dataController.getWeaponsCloseCombat();		
		printList(weaponsCloseCombat);
				
		System.out.println("\nTest Engine Parts\n");
		List<Part> partsEngine = dataController.getPartsEngine();		
		printList(partsEngine);
	}

	public static void testHTMLImport() {
		ImportExportController importExportController = new ImportExportController();
		importExportController.updateCSVFiles();
	}

		

}
